package net.pimpas.persistence.hibernate.serviceprovider;

import net.pimpas.core.serviceprovider.ServiceProviderFactory;
import net.pimpas.framework.PimpasFramework;
import net.pimpas.persistence.serviceprovider.PersistenceServiceProvider;

public class HibernateServiceProviderFactoryImpl implements ServiceProviderFactory<HibernateServiceProvider> {

	public static synchronized HibernateServiceProvider getPersistenceServiceProvider(Object... params) {
		return new HibernateServiceProviderFactoryImpl().getServiceProvider(params);
	}
	
	public synchronized HibernateServiceProvider getServiceProvider(Object... params) {
		return (HibernateServiceProvider) PimpasFramework.getCurrentInstance().getServiceProvider(PersistenceServiceProvider.class, params);
	}
}